<template>
    <!-- 业绩提成-提成单详情-操作日志 -->
    <div>
        <h3> 操作日志（共{{total}}条）</h3>
        <zm-table-data
        :data="tableParams.data"
        :columns="operationLog"
        :fetch="loadList"
        :table-params="tableParams"
        :mutilple="false"
      ></zm-table-data>
    </div>
</template>

<script>
import tableMixin from '@/mixins/zmTableMixin'
import {operationLog} from './const.js'
import {commissionLogList} from '@/api/src/salesmanCommission'
export default {
  mixins: [tableMixin],
  props: {
    performanceId: {
      type: String,
      required: true
    }
  },
  data () {
    return {
      total: ''
    }
  },
  computed: {
    operationLog () {
      return operationLog(this)
    }
  },
  methods: {
    async loadList () {
      const _res = await commissionLogList(this.assignQuery({id: this.performanceId}))
      this.initialTableData(_res.list, _res.count)
      this.total = _res.count
    }
  }
}
</script>

<style>

</style>
